package Tian.controller;

import Tian.model.UserInfo;
import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.RequestMapping;

import java.util.ArrayList;
import java.util.List;

@Controller
public class oneController {
   // @RequestMapping(value = {"","/login"})
    public String login(Model model){
        List<UserInfo> userInfos = new ArrayList<>();
        for (int i=0; i<20;i++){
            UserInfo userInfo = new UserInfo();
            userInfo.setUId(i);
            userInfo.setUserName("1"+i);
            userInfos.add(userInfo);
        }
        model.addAttribute("userInfo",userInfos);
        return "login";
    }
}
